package com.system.base;

import lombok.extern.slf4j.Slf4j;

@Slf4j
public class MyTask implements Runnable {
	private String taskId;
	private String taskName;
	private Long orderId;
	private Integer resourceType;

	public MyTask(String taskId, String taskName, Long orderId, Integer resourceType) {
		this.taskId = taskId;
		this.taskName = taskName;
		this.orderId = orderId;
		this.resourceType = resourceType;
	}

	public String getTaskId() {
		return taskId;
	}

	public void setTaskId(String taskId) {
		this.taskId = taskId;
	}

	public String getTaskName() {
		return taskName;
	}

	public void setTaskName(String taskName) {
		this.taskName = taskName;
	}

	public Long getOrderId() {
		return orderId;
	}

	public void setOrderId(Long orderId) {
		this.orderId = orderId;
	}

	public Integer getResourceType() {
		return resourceType;
	}

	public void setResourceType(Integer resourceType) {
		this.resourceType = resourceType;
	}

	@Override
	public void run() {
		try {
			// System.out.println("run taskId = " + this.taskId + " taskName " + this.getTaskName() + " resourceType " + this.getResourceType() + " orderId " + this.getOrderId());
			log.info("run taskId = " + this.taskId + " taskName " + this.getTaskName() + " resourceType " + this.getResourceType() + " orderId " + this.getOrderId());
		} catch (Exception e) {
			e.printStackTrace();
		}

	}
}